﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<Gola.VN.Scb.Web.Common.PaginatedList<Gola.VN.Scb.Web.Common.Entities.ProductEntity>>" %>
<%@ Import Namespace="Gola.VN.Scb.Web.Common" %>
<div class="ListProducts vl">
    <ul>
        <% foreach (var product in Model)
           {
        %>
        <li class="item">
            <div class="pCompany">
                <div class="company">
                    <%--Show map--%>
                    <div id="bando" class="provider">
                        <a href="#?w=800" class="poplight" rel="product_info" poplightid='<%:"poplight" + product.ProviderId.ToString()%>'>
                            <%:product.ProdiverName%><img src="/Content/Images/spacer.gif" class="mapIcon" alt="Bản đồ"></a>
                    </div>
                </div>
                <%--<div class="wrStar">
                    <span class="star3">3 sao</span></div>--%>
                <div class="pSupport" style="display: none;">
                    <span>Hỗ trợ:</span> <a href="ymsgr:sendim?mediamart01&amp;m=Xin chao, toi muon hoi ve san pham Kệ ti vi , kt ( 900x450 ) mm - TV 028 dang tai http://demo.gola.vn/phu-kien-tivi/media-mart/ke-ti-vi-kt-900x450-mm-tv-028/31717.html !"
                        title="Chat in Yahoo!">
                        <img src="http://opi.yahoo.com/online?u=mediamart01&amp;m=g&amp;t=5" alt="YM"></a>
                    <a href="ymsgr:sendim?mediamart03&amp;m=Xin chao, toi muon hoi ve san pham Kệ ti vi , kt ( 900x450 ) mm - TV 028 dang tai http://demo.gola.vn/phu-kien-tivi/media-mart/ke-ti-vi-kt-900x450-mm-tv-028/31717.html !"
                        title="Chat in Yahoo!">
                        <img src="http://opi.yahoo.com/online?u=mediamart03&amp;m=g&amp;t=5" alt="YM"></a>
                    <a href="ymsgr:sendim?mediamart02&amp;m=Xin chao, toi muon hoi ve san pham Kệ ti vi , kt ( 900x450 ) mm - TV 028 dang tai http://demo.gola.vn/phu-kien-tivi/media-mart/ke-ti-vi-kt-900x450-mm-tv-028/31717.html !"
                        title="Chat in Yahoo!">
                        <img src="http://opi.yahoo.com/online?u=mediamart02&amp;m=g&amp;t=5" alt="YM"></a>
                </div>
            </div>
            <div id="popup_chart31717" class="popup_block bgGray">
                <div id="my_chart31717">
                </div>
            </div>
            <div class="price">
                <a href="javascript:poplightChart('popup_chart31717','my_chart31717',600,300,31717);"
                    title="Biểu đồ giá" rel="popup_chart31717" class="poplight"><span>
                        <%: product.PriceDisplay%></span>
                    <%: product.LastPriceDisplay %>
                </a>
                <%if (product.EnableGoToWebsite)
                  {%>
                <a class="websiteBtn" target="_blank" href="<%: Url.RouteUrl("gotoWebsite",new {id=product.Id,provider= product.ProdiverName.ConvertToUnSign(), keyword =product.Title.ConvertToUnSign()})%>">
                    Tới cửa hàng</a>
                <%}
                  else
                  {%>
                <%--todo: show compare style="margin-left: -30px;"--%>
                <a href="<%: product.View %>" class="compareBtn">So sánh giá</a>
                <%}%>
            </div>
            <div class="imgPrd">
                <%if (ViewData["EnableAddProductCompare"] != null && (bool)ViewData["EnableAddProductCompare"])
                  {%>
                <a href="javascript:" onclick="displayProduct('<%:product.Id%>')" class="padd_compare">
                    <img src="/Content/Images/addProduct.gif" width="16px" alt="Thêm <%:product.Title%> vào danh sách so sánh" />
                </a>
                <%}%>
                <a title="<%: product.Title%>" href="<%: product.View %>" data-tooltip="one1" tipid='<%:"tip"+ product.Id.ToString()%>'>
                    <img src="<%: product.ImageUrl %>" alt="<%: product.Title%>" />
                </a>
            </div>
            <div class="pDetail">
                <h3>
                    <a title="<%: product.Title %>" href="<%: product.View %>" class="title">
                        <%: product.Title %></a></h3>
                <div class="pDes">
                    <%:MvcHtmlString.Create(product.Description)%>
                </div>
                <div class="sale">
                    <% if (!string.IsNullOrWhiteSpace(product.PromotionNonHtmltag))
                       {%>
                    <span></span>
                    <%:MvcHtmlString.Create(product.PromotionNonHtmltag)%>
                    <%}%>
                </div>
            </div>
            <!--HTML for the tooltips-->
            <div class="stickytooltip">
                <div id='<%:"tip" + product.Id.ToString()%>' class="atip">
                    <div class="title">
                        <%: product.Title %></div>
                    <div class="picture">
                        <img src="<%:product.ImageUrl %>" alt="<%: product.Title %>">
                    </div>
                    <br>
                    <div class="pDetail" style="width: 350px">
                        <%:MvcHtmlString.Create(product.Description)%>
                    </div>
                </div>
                <div class="stickystatus">
                </div>
            </div>
        </li>
        <%
           }
        %>
        <% if (Model.Count <= 0)
           {%>
        <li>
            <br />
            <h3>
                KHÔNG CÓ SẢN PHẨM NÀO.</h3>
            <br />
            <%}%>
        </li>
    </ul>
</div>
<!--HTML for the tooltips-->
<div id="mystickytooltip" class="stickytooltip">
    <div id="one1" class="atip" style="padding: 5px">
    </div>
    <div class="stickystatus">
    </div>
</div>
